package com.dyxy.tms.model;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

import com.dyxy.tms.AppConfig;
import com.dyxy.tms.UserInfo;

public class GetData {
	private List<Map<String, Object>> list;

	public List<Map<String, Object>> getIndexIconData() {
//		list = new ArrayList<Map<String, Object>>();
//		int[] icon = { R.drawable.aaa111, R.drawable.ic_launcher, R.drawable.aaa111, R.drawable.ic_launcher,
//				R.drawable.aaa111, R.drawable.ic_launcher, R.drawable.aaa111, R.drawable.ic_launcher, R.drawable.aaa111,
//				R.drawable.ic_launcher };
//		String[] name = { "我是名称", "我是名称", "我是名称", "我是名称", "我是名称", "我是名称", "我是名称", "我是名称", "我是名称", "我是名称" };
//		for (int i = 0; i < icon.length; i++) {
//			Map<String, Object> map = new HashMap<String, Object>();
//			map.put("icon", icon[i]);
//			map.put("name", name[i]);
//			list.add(map);
//		}
		String url = AppConfig.url + "/TMS/index.php";
		list = UserInfo.getIndexIconList(url);
		return list;
	}

	public List<Map<String, Object>> getIndexCourseData() {
		list = new ArrayList<Map<String, Object>>();
		String[] time = { "1-2", "3-4", "5-6", "7-8", "9-10" };
		String[] name = { "三教A408，计算机文化基础", "实训楼B座512，软件测试基础", "实训楼B座512，软件测试基础实训楼B座512，软件测试基础实训楼B座512，软件测试基础实训楼B座512，软件测试基础", "实训楼B座512，软件测试基础", "实训楼B座512，软件测试基础" };

		for (int i = 0; i < time.length; i++) {

			Map<String, Object> map = new HashMap<String, Object>();
			map.put("time", time[i]);
			map.put("name", name[i]);
			list.add(map);
		}
		return list;
	}

}
